]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
inhibitShorcutsDialog: Fix permission check
authorFlorian Müllner <fmuellner@gnome.org>
Fri, 18 Nov 2022 21:40:31 +0000 (22:40 +0100)
committerMarge Bot <marge-bot@gnome.org>
Sat, 19 Nov 2022 00:48:25 +0000 (00:48 +0000)
Each permission entry is an array of strings, so checking that against
the expected string itself will always fail.

https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/6107

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2548>

js/ui/inhibitShortcutsDialog.js

index b6f1330b2cfb8a9897844b0443d1db94154a5442..7c3d159968f8db178b814fa186109b8fe8ce4879 100644 (file)
@@ -143,7 +143,7 @@ var InhibitShortcutsDialog = GObject.registerClass({
 
                 if (permissions[appId] === undefined) // Not found
                     this._dialog.open();
-                else if (permissions[appId] === GRANTED)
+                else if (permissions[appId][0] === GRANTED)
                     this._emitResponse(DialogResponse.ALLOW);
                 else
                     this._emitResponse(DialogResponse.DENY);